package com.stephen.redisdemo.entity.enums;

/**
 * @author: stephen
 * @create: 2020-02-06 12:24
 * @description: 返回结果的枚举
 */

public enum ResultEnum {

    SUCCUSS(0,"成功"),
    FAIL(-1,"失败"),
    JSON_PARSE_ERROR(10001,"JSON解析异常"),
    PARAM_ERROR(10002,"参数不正确");

    private Integer code;

    private String msg;

    public void setCode(Integer code) {
        this.code = code;
    }

    public Integer getCode() {
        return code;
    }

    public String getMsg() {
        return msg;
    }

    public void setMsg(String msg) {
        this.msg = msg;
    }

    ResultEnum(Integer code, String msg) {
        this.code = code;
        this.msg = msg;
    }


}
